import React, { useMemo } from "react";
import styles from "./styles.module.scss";
const MainHeader = () => {
    const userData = useMemo(() => {
        const txt = sessionStorage.getItem("AdminData");
        return txt && txt?.length > 0 ? JSON.parse(txt) : {};
    }, [])
    return (
        <section>
            <h1 className={styles.header}>用户：{userData.userName || userData.loginName || "未知"}</h1>
        </section>
    );
};

export default MainHeader;
